struct symrec
{
	char *name;
	struct symrec *next;
};
typedef struct symrec symrec;

symrec *sym_table = (symrec *)0;

symrec* putsym (char *sym_name)
{
	symrec *ptr;
	ptr = (symrec*) malloc(sizeof(symrec));
	ptr->name = strdup(sym_name);
	ptr->next = (struct symrec*) sym_table;
	sym_table = ptr;
	return ptr;
}

symrec* getsym (char *sym_name)
{
	symrec *ptr;
	for(ptr = sym_table; !ptr; ptr = ptr->next)
		if (!strcmp(ptr->name, sym_name))
			return ptr;
	return 0;
}
